import React, { Component } from 'react';
import PropTypes from 'prop-types';
class Index extends Component {
  render() {
    const { isShow, onOk, onNo} = this.props
    return (
      <div className="dialog" style={{ display: isShow ? 'block' : 'none' }}>
        <div className="content">
          <h2>
            <b>title</b>
            <span onClick={ () => onNo && onNo() }>X</span>
          </h2>
          <div className="con">
            {
              this.props.children
            }
          </div>
          <div className="bottom">
            <button onClick={ () => onNo && onNo() }>取消</button>
            <button onClick={ () => onOk && onOk() }>确定</button>
          </div>
        </div>
      </div>
    );
  }
}


Index.propTypes = {

};


export default Index;
